//
// Created by 11510 on 2024/7/29.
//

#ifndef WEB_DEDUPLICATION_CONFIGURATION_H
#define WEB_DEDUPLICATION_CONFIGURATION_H


#include <string>
#include <map>
#include <set>
#include <fstream>


class Configuration {
private:
    const char *const HMM_PATH = "../dict/hmm_model.utf8";
    const char *const IDF_PATH = "../dict/idf.utf8";
    const char *const DICT_PATH = "../dict/jieba.dict.utf8";
    const char *const STOP_WORD_PATH = "../dict/stop_words.utf8";
    const char* const USER_DICT_PATH = "../dict/user.dict.utf8";

    // 私有化构造函数以防止实例化
    Configuration(){}

    // 私有化拷贝构造函数和赋值操作符，以防止拷贝实例
    Configuration(const Configuration&) = delete;
    Configuration& operator=(const Configuration&) = delete;


public:
    // 获取单例实例的方法
    const static Configuration& getInstance() {
        static Configuration instance;
        return instance;
    }

    const char *const getDictPath() const {
        return DICT_PATH;
    }

    const char *const getHmmPath() const {
        return HMM_PATH;
    }

    const char *const getIdfPath() const {
        return IDF_PATH;
    }

    const char *const getStopWordPath() const {
        return STOP_WORD_PATH;
    }

    const char *const getUserDictPath() const {
        return USER_DICT_PATH;
    }
};


#endif //WEB_DEDUPLICATION_CONFIGURATION_H
